<?php

/**
* Creates a textArea
*
*/
class textarea extends elementInner
{
    public $text;

    function textarea($id=NULL, $rows=5, $columns=5, $text=NULL, $class=NULL, $label=NULL)
    {
        $text = htmlentities('textarea',$text); //filter the text
        parent::elementInner($id, NULL, $class,$label);
        $this->addAttribute('rows', $rows);
        $this->addAttribute('cols', $columns);
        $this->addInner($text);
        $this->addAttribute('name', $id);
    }

    public function getValue()
    {
        return $this->getInner;
    }


    public function setValue($text)
    {
        $this->setInnerHTML( $text ) ;
    }
}
?>